//
//  XLConsumeModel.m
//  XiangLove
//
//  Created by 宋振 on 2018/8/3.
//  Copyright © 2018年 BAOMIHUA.COM. All rights reserved.
//

#import "XLConsumeModel.h"

@implementation XLConsumeModel

- (NSString *)StartTime
{
    if (_StartTime) {
        NSArray *times = [_StartTime componentsSeparatedByString:@" "];
        
        if (times.count > 1) {
            return times[1];
        }
    }
    
    return _StartTime;
}

- (NSString *)EndTime
{
    if (_EndTime) {
        NSArray *times = [_EndTime componentsSeparatedByString:@" "];
        
        if (times.count > 1) {
            return times[1];
        }
    }
    
    return _EndTime;
}

- (NSString *)ChangeMoneyStr
{
    return [NSDecimalNumber decimalNumberWithString:[NSString stringWithFormat:@"%.lf", self.ChangeMoney.doubleValue*10]].stringValue;
}

- (NSInteger)CountNumInt
{
    return [NSDecimalNumber decimalNumberWithString:[NSString stringWithFormat:@"%.lf", self.CountNum.doubleValue]].integerValue;
}

@end
